package com.gztms.blogmgnt.pojo.vo;

import com.baomidou.mybatisplus.annotation.*;
import com.fasterxml.jackson.annotation.JsonFormat;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;

import java.util.Date;
import java.util.List;

/**
 * @author Zoey
 * @date 2023/5/2 12:46
 * @Description TODO
 **/
@Data
@AllArgsConstructor
@NoArgsConstructor
public class CommentVO {
    private Integer id;
    //文章id
    private Integer blogId;
    //根评论id
    private Integer rootId;
    //评论内容
    private String content;
    //回复者id
    private String toCommentUid;
    //回复评论id
    private Integer toCommentId;
    //用户编号
    private String createdBy;
    //评论时间
    @JsonFormat(pattern="yyyy-MM-dd HH:mm:ss",timezone="GMT+8")
    private Date createTime;
    // 用户名称
    private String username;
    // 回复者名称
    private String toCommentUsername;
    // 头像
    private String avatar;

    private String toCommentAvatar;

    // 子评论集合
    private List<CommentVO> children;

}
